package com.mask.web.base.controller;



import com.alibaba.fastjson2.JSON;
import com.mask.common.core.model.R;
import com.mask.common.log.annotation.Log;
import com.mask.common.log.util.LogUtils;
import com.sca.base.api.service.*;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;


/**
 * @Author：jian
 * @Package：com.mask.web.base.controller
 * @Project：mask-sca-cloud
 * @name：HelloController
 * @Date：2025/3/5 17:45
 * @Filename：HelloController
 */
@Log(module = "测试")
@RestController
public class HelloController {
    @DubboReference
    private RpcHelloService helloService;

    @GetMapping("/hello")
    public String echo() {
        LogUtils.info("测试日志输出");
        R<String> stringR = helloService.sysHello();
        String data = stringR.getData();
        return JSON.toJSONString(helloService.sysHello());
    }

}
